package com.markus.basic.设计模式.静态代理模式;

/**
 * Author:markusZhang
 * Date:Create in 2020/8/30 14:20
 * todo:
 */
public class RealImage implements Image {

    private String fileName;

    public RealImage(String fileName){
        this.fileName = fileName;
        loadDisk(fileName);
    }

    private void loadDisk(String fileName) {
        System.out.println("从磁盘中加载"+fileName);
    }

    @Override
    public void display() {
        System.out.println("展示图片："+fileName);
    }
}
